package org.cying.main.feign;

import org.cying.main.domain.SampleResult;
import org.cying.main.domain.Student;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

@Component
@FeignClient(value = "Sign-Server")
public interface ClientFeignSign {

    @GetMapping(value = "/sign/alter/refresh")
    SampleResult<Map<Long, Student>> alterRefresh();

    @GetMapping(value = "/unsign/get/duty")
    SampleResult<Map<Long, Student>> getDuty();

    @PostMapping(value = "/unsign/post/record")
    SampleResult<Object> postRecord(
            @RequestParam(value = "info", required = true) String info
    );


}